<%@ include file="/WEB-INF/jsp/includes/header.jsp"%>
<table width="592">
	<tr>
		<td class="title"><s:property value="title"/></td>
	</tr>
	<tr><td>&nbsp;</td></tr>		
	<s:if test="pacient != null">
		<s:form id="visitaForm" action="showVisita" method="post" validate="true">
			<s:push value="pacient">
				<!-- Inici dades comuns dels usuaris -->
				<tr id="row_<s:property  value="id"/>">
					<s:hidden name="id" value="%{id}"/>
					<td><s:label key="nom"/></td>
				</tr>
				<tr>
					<td><s:label key="primerCognom"/></td>
				</tr>
				<tr>
					<td><s:label key="segonCognom"/></td>
				</tr>
				<!-- Fi dades comuns dels usuaris -->
			</s:push>
			<tr><td>&nbsp;</td></tr>
			<!-- Inici dades de la visita -->
			<s:if test="visita != null">
				<s:push value="visita">
					<tr>
						<td class="subtable"><s:text name="visita.detall"/></td>
					</tr>
					<tr>
						<td><s:label key="anamnesi"/></td>
					</tr>
					<tr>
						<s:date name="dataHora" format="dd/MM/yyyy HH:mm" id="fmtDataHora"/>
						<td><s:label key="dataHora" value="%{fmtDataHora}"></s:label></td>
					</tr>
					<tr>
						<td><s:label key="diagnosi"/></td>
					</tr>
					<tr>
						<td><s:label key="tema"/></td>
					</tr>
					<tr>
						<td><s:label key="tractament"/></td>
					</tr>
					<tr>
						<s:date name="dataAlta" format="dd/MM/yyyy HH:mm" id="fmtDataAlta" />
						<td><s:label key="dataAlta" value="%{fmtDataAlta}"/></td>
					</tr>				
					<tr>
						<s:date name="dataModificacio" format="dd/MM/yyyy HH:mm" id="fmtDataModificacio" />
						<td><s:label key="dataModificacio" value="%{fmtDataModificacio}"/></td>
					</tr>				
					<tr><td>&nbsp;</td></tr>
					<!-- Metge associat -->				
					<tr>
						<td class="subtable"><s:text name="metge.visita"/></td>
					</tr>
					<tr>
						<td>
							<s:property value="metge.nom"/> <s:property value="metge.primerCognom"/>
							<s:property value="metge.segonCognom"/>.
						</td>
					</tr>
					<tr>
						<td><s:text name="especialitat_en"/><s:property value="metge.especialitat"/>. 
						</td>
					</tr>
					<tr>
						<td><s:text name="collegiat"/><s:property value="metge.numeroColegiat"/>
						</td>
					</tr>
					
				</s:push>
			</s:if>
		</s:form>
	</s:if>
</table>

<table class="actions" width="592">
	<tr><td>&nbsp;</td></tr>
	<tr><td><s:text name="actions"/></td></tr>
	<tr>
		<td><a href='<s:url action="showHistorial" includeParams="none"/>'><s:text name="historial.go"/></a></td>	
		<td><a href='<s:url action="showPacient" includeParams="none"/>'><s:text name="pacient.go"/></a></td>
		<td><a href="<s:url action="logout" includeParams="none"/>"><s:text name="logout"/></a></td>
	</tr>
</table>

<%@ include file="/WEB-INF/jsp/includes/footer.jsp"%>
